#ifndef GAN_H
#define GAN_H
#include <QDialog>
#include "painter.h"
#include "ui_painter.h"

class Gan
{
private:
    float Bar[4];
    int Min_Bar_Num;
    int Max_Bar_Num;
    float Min_Bar_Length;
    float Max_Bar_length;
    float Min_Max_Bar_sum;
    float Other_Bar_sum;
    int Other_Bar_num[2];
private:
    void MinBar(float* Bar);
    void MaxBar(float* Bar);
    void OtherBarSum();
    void Judge();
    bool CheckInput();

public:
    Gan(double a,double b, double c,double d,Ui::painter* ui_ptr);
    ~Gan();
    void Check();
public:
    Ui::painter* ui;
    bool isInputLeagal;
    double LengthGan1;
    double LengthGan2;
    double LengthGan3;
    double LengthGan4;
};

#endif // GAN_H
